package com.shop.zkmall.app.controller.a;

import com.shop.zkmall.app.domain.req.CreateOrderReq;
import com.shop.zkmall.app.service.a.ICereBuyerLiveRoomService;
import com.shop.zkmall.app.service.a.ICereShopMarketingService;
import com.shop.zkmall.app.service.order.CereShopOrderService;
import com.shop.zkmall.commons.result.R;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping("order")
@RequiredArgsConstructor
@Tag(name = "订单模块", description = "订单模块")
public class OrderController {

    private final ICereShopMarketingService cereShopMarketingService;

    /**
     * 创建订单
     */
    @PostMapping("/createOrder")
    @Operation(summary = "创建订单")
    public R<?> createOrder(@RequestBody CreateOrderReq createOrderReq) {
        return cereShopMarketingService.createOrder(createOrderReq);
    }



    /**
     * 支付
     */
    @PostMapping("/pay")
    @Operation(summary = "支付")
    public R<?> pay(@Param("orderId") Long orderId) {
        return null;
    }
}
